package cn.stazxr.deepseekchat.config;

import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;
import org.springframework.context.annotation.Bean;
import io.swagger.v3.oas.models.ExternalDocumentation;
import org.springframework.context.annotation.Configuration;

/**
 * http://ip:port/swagger-ui/index.html
 *
 * @author talentestors
 * @version 1.0
 * @since 2025.3.15
 **/
@SuppressWarnings("JavadocLinkAsPlainText")
@Configuration
public class OpenAPIConfig {

	@SuppressWarnings("AlibabaLowerCamelCaseVariableNaming")
	@Bean
	public OpenAPI openAPI() {
		return new OpenAPI()
			.info(new Info()
				.title("接口文档标题")
				.description("SpringBoot3 集成 Swagger3接口文档")
				.version("v1"))
			.externalDocs(new ExternalDocumentation()
				.description("项目API文档")
				.url("/"));
	}

}
